<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8">
    <title></title>
  </head>
  <body>
    <script type="text/javascript">
      console.log("==========return 函数调用======================");
      function add(x,y){
        return x+y;
        console.log("返回后面的代码");
      }
      console.log(add(2,3));
      console.log("==========递归==========================");
      function fib(num){
        if (num > 2){
          return fib(num - 2) + fib(num - 1);
        }else{
          return 1;
        }
      }
      console.log(fib(6));
      console.log("=========凡是可以使用值的地方，就能使用函数=====================");
      var option = add;
      console.log(option(5,6));
      function a(op) {
        return op;
      }
      a(add(8,9));
      console.log(a(add(8,9)));
      var b = {
        name : add,
      }
    </script>
  </body>
</html>
